<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>编辑区划</title>
    <link rel="stylesheet" type="text/css" href="/static/hplus/css/bootstrap.min.css">
    <link rel="stylesheet" type="text/css" href="/static/hplus/css/plugins/iCheck/custom.css">
    <link rel="stylesheet" type="text/css" href="/static/hplus/css/style.css">
    <link rel="stylesheet" type="text/css" href="/static/layer/skin/layer.css">
    <style type="text/css">
        .form-control {width: 200px;}
        .col-sm-10 {width: 250px;display: inline-block;}
        .col-sm-2 {text-align: right;width: 125px;}
    </style>
</head>
<body class="gray-bg">
<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>编辑区划</h5>
                </div>
                <div class="ibox-content">
                    <form class="form-horizontal" onsubmit="return false">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">父级</label>
                            <div class="col-sm-10">
                                <select id="pcode" name="pcode" class="form-control">
                                    <option value="">请选择父级</option>
                                    {foreach $pcodes as $p}
                                    <option value="{$p.code}" {if($p.code===$district.pcode)}selected="1"{/if}>{$p.name}</option>
                                    {/foreach}
                                </select>
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">区划编码</label>
                            <div class="col-sm-10">
                                <input type="text" class="form-control" id="code" name="code" value="{$district.code}">
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">区划名称</label>
                            <div class="col-sm-10">
                                <input type="text" class="form-control" id="name" name="name" value="{$district.name}">
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">区划级别</label>
                            <div class="col-sm-10">
                                <input type="text" class="form-control" id="level" name="level" value="{$district.level}">
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">状态</label>
                            <div class="col-sm-10">
                                <div class="radio i-checks">
                                    <label class>
                                        <div class="iradio_square-green">
                                            <input type="radio" value="1" name="status" {if(intval($district.status)===1)}checked="1"{/if} style="position: absolute; opacity: 0;">
                                            <ins class="iCheck-helper"></ins>
                                        </div>
                                        正常</label>
                                    <label class>
                                        <div class="iradio_square-green">
                                            <input type="radio" value="2" name="status" {if(intval($district.status)===2)}checked="1"{/if} style="position: absolute; opacity: 0;">
                                            <ins class="iCheck-helper"></ins>
                                        </div>
                                        撤销</label>
                                </div>
                            </div>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>
</body>
<script type="text/javascript" src="/static/hplus/js/jquery.min.js?v={php}echo time(){/php}"></script>
<script type="text/javascript" src="/static/hplus/js/plugins/iCheck/icheck.min.js?v={php}echo time(){/php}"></script>
<script type="text/javascript">
    $(function () {
        $(".i-checks").iCheck({checkboxClass: "icheckbox_square-green", radioClass: "iradio_square-green"});
    })
</script>
</html>
